home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.mactech.com 2010
/
ftp.mactech.com.tar
/
ftp.mactech.com
/
machack
/
Hacks97
/
WarriorsProgress.sit
/
Warrior’s Progress
/
source code
/
Source
/
Libraries
/
Events
/
EventQueue.h
< prev
next >
Wrap
Text File
|
1997-06-28
|
957b
|
49 lines
// EventQueue.h
#ifndef EventQueue_h
#define EventQueue_h
#ifndef Integers_h
#include "Integers.h"
#endif
#ifndef EventManagerUser_h
#include "EventManagerUser.h"
#endif
#ifndef Assert_h
#include "Assert.h"
#endif
#ifndef FiniteQueue_h
#include "FiniteQueue.h"
#endif
class EventQueue: public EventManagerUser
{
private:
FiniteQueue< EventRecord, 2 > events;
EventRecord *previous;
EventRecord *current;
EventRecord *next;
EventQueue();
static bool Valid( const EventRecord& );
static bool Exists( WindowPeek );
void Advance();
public:
static EventQueue& The();
const EventRecord& operator*() const { Assert( current != 0 ); return *current; }
const EventRecord *operator->() const { Assert( current != 0 ); return current; }
void operator++();
void operator++(int) { operator++(); }
void AdvanceWithoutWaiting();
void operator--();
void operator--(int) { operator--(); }
};
#endif